﻿ 

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_avgcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzqcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_jzcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_curcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_balqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_preqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_djqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] DROP CONSTRAINT [DF_custwork_detailinfo_ccqty]
GO

/****** Object:  Table [dbo].[custwork_works]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_works]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_works]
GO

/****** Object:  Table [dbo].[custwork_work_period]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_work_period]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_work_period]
GO

/****** Object:  Table [dbo].[custwork_work]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_work]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_work]
GO

/****** Object:  Table [dbo].[custwork_trans_work]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_trans_work]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_trans_work]
GO

/****** Object:  Table [dbo].[custwork_detailinfo]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_detailinfo]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_detailinfo]
GO

/****** Object:  Table [dbo].[custwork_curcb_period]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_curcb_period]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_curcb_period]
GO

/****** Object:  Table [dbo].[custwork_balcb_period]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_balcb_period]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_balcb_period]
GO

/****** Object:  Table [dbo].[custwork_avg]    Script Date: 2024-10-24 12:25:46 ******/
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[custwork_avg]') AND type in (N'U'))
DROP TABLE [dbo].[custwork_avg]
GO

/****** Object:  Table [dbo].[custwork_avg]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_avg](
	[iyear] [int] NULL,
	[imonth] [int] NULL,
	[citem_id] [nvarchar](60) NULL,
	[citemname] [nvarchar](255) NULL,
	[ccode] [nvarchar](40) NOT NULL,
	[avgAmount] [decimal](38, 13) NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_balcb_period]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_balcb_period](
	[iyear] [int] NULL,
	[imonth] [int] NULL,
	[citem_id] [nvarchar](60) NULL,
	[citemname] [nvarchar](255) NULL,
	[ccode] [nvarchar](40) NOT NULL,
	[ccode_name] [nvarchar](100) NULL,
	[balamount] [money] NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_curcb_period]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_curcb_period](
	[iyear] [int] NULL,
	[imonth] [int] NULL,
	[citem_id] [nvarchar](60) NULL,
	[citemname] [nvarchar](255) NULL,
	[ccode] [nvarchar](40) NOT NULL,
	[ccode_name] [nvarchar](100) NULL,
	[cbamount] [money] NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_detailinfo]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_detailinfo](
	[iyear] [int] NULL,
	[imonth] [int] NULL,
	[citemcode] [nvarchar](50) NULL,
	[citemname] [nvarchar](500) NULL,
	[ccqty] [decimal](28, 4) NULL,
	[djqty] [decimal](28, 4) NULL,
	[preqty] [decimal](28, 4) NULL,
	[balqty] [decimal](28, 4) NULL,
	[curcb] [decimal](28, 2) NULL,
	[curcb1] [decimal](28, 2) NULL,
	[curcb2] [decimal](28, 2) NULL,
	[curcb3] [decimal](28, 2) NULL,
	[curcb4] [decimal](28, 2) NULL,
	[curcb5] [decimal](28, 2) NULL,
	[curcb6] [decimal](28, 2) NULL,
	[curcb7] [decimal](28, 2) NULL,
	[curcb8] [decimal](28, 2) NULL,
	[curcb9] [decimal](28, 2) NULL,
	[curcb10] [decimal](28, 2) NULL,
	[curcb11] [decimal](28, 2) NULL,
	[curcb12] [decimal](28, 2) NULL,
	[curcb13] [decimal](28, 2) NULL,
	[curcb14] [decimal](28, 2) NULL,
	[curcb15] [decimal](28, 2) NULL,
	[curcb16] [decimal](28, 2) NULL,
	[curcb17] [decimal](28, 2) NULL,
	[curcb18] [decimal](28, 2) NULL,
	[curcb19] [decimal](28, 2) NULL,
	[jzcb] [decimal](28, 2) NULL,
	[jzcb1] [decimal](28, 2) NULL,
	[jzcb2] [decimal](28, 2) NULL,
	[jzcb3] [decimal](28, 2) NULL,
	[jzcb4] [decimal](28, 2) NULL,
	[jzcb5] [decimal](28, 2) NULL,
	[jzcb6] [decimal](28, 2) NULL,
	[jzcb7] [decimal](28, 2) NULL,
	[jzcb8] [decimal](28, 2) NULL,
	[jzcb9] [decimal](28, 2) NULL,
	[jzcb10] [decimal](28, 2) NULL,
	[jzcb11] [decimal](28, 2) NULL,
	[jzcb12] [decimal](28, 2) NULL,
	[jzcb13] [decimal](28, 2) NULL,
	[jzcb14] [decimal](28, 2) NULL,
	[jzcb15] [decimal](28, 2) NULL,
	[jzcb16] [decimal](28, 2) NULL,
	[jzcb17] [decimal](28, 2) NULL,
	[jzcb18] [decimal](28, 2) NULL,
	[jzcb19] [decimal](28, 2) NULL,
	[jzqcb] [decimal](28, 2) NULL,
	[jzqcb1] [decimal](28, 2) NULL,
	[jzqcb2] [decimal](28, 2) NULL,
	[jzqcb3] [decimal](28, 2) NULL,
	[jzqcb4] [decimal](28, 2) NULL,
	[jzqcb5] [decimal](28, 2) NULL,
	[jzqcb6] [decimal](28, 2) NULL,
	[jzqcb7] [decimal](28, 2) NULL,
	[jzqcb8] [decimal](28, 2) NULL,
	[jzqcb9] [decimal](28, 2) NULL,
	[jzqcb10] [decimal](28, 2) NULL,
	[jzqcb11] [decimal](28, 2) NULL,
	[jzqcb12] [decimal](28, 2) NULL,
	[jzqcb13] [decimal](28, 2) NULL,
	[jzqcb14] [decimal](28, 2) NULL,
	[jzqcb15] [decimal](28, 2) NULL,
	[jzqcb16] [decimal](28, 2) NULL,
	[jzqcb17] [decimal](28, 2) NULL,
	[jzqcb18] [decimal](28, 2) NULL,
	[jzqcb19] [decimal](28, 2) NULL,
	[avgcb] [decimal](28, 6) NULL,
	[avgcb1] [decimal](28, 6) NULL,
	[avgcb2] [decimal](28, 6) NULL,
	[avgcb3] [decimal](28, 6) NULL,
	[avgcb4] [decimal](28, 6) NULL,
	[avgcb5] [decimal](28, 6) NULL,
	[avgcb6] [decimal](28, 6) NULL,
	[avgcb7] [decimal](28, 6) NULL,
	[avgcb8] [decimal](28, 6) NULL,
	[avgcb9] [decimal](28, 6) NULL,
	[avgcb10] [decimal](28, 6) NULL,
	[avgcb11] [decimal](28, 6) NULL,
	[avgcb12] [decimal](28, 6) NULL,
	[avgcb13] [decimal](28, 6) NULL,
	[avgcb14] [decimal](28, 6) NULL,
	[avgcb15] [decimal](28, 6) NULL,
	[avgcb16] [decimal](28, 6) NULL,
	[avgcb17] [decimal](28, 6) NULL,
	[avgcb18] [decimal](28, 6) NULL,
	[avgcb19] [decimal](28, 6) NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_trans_work]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_trans_work](
	[iyear] [int] NULL,
	[imonth] [int] NULL,
	[citemcode] [nvarchar](100) NULL,
	[ccode] [nvarchar](40) NULL,
	[transAmount] [decimal](38, 6) NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_work]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_work](
	[cNo] [nvarchar](40) NULL,
	[cDepCode] [nvarchar](100) NULL,
	[cMaker] [nvarchar](30) NULL,
	[dMakeDateEx] [datetime] NULL,
	[dMakeDate] [datetime] NULL,
	[cMender] [nvarchar](30) NULL,
	[dModifyDateEx] [datetime] NULL,
	[dModifyDate] [datetime] NULL,
	[cAuditor] [nvarchar](30) NULL,
	[dAuditDateEx] [datetime] NULL,
	[dAuditDate] [datetime] NULL,
	[cMemo] [nvarchar](4000) NULL,
	[cvencode] [nvarchar](100) NULL,
	[custwork_work_PK] [int] NOT NULL,
	[iswfcontrolled] [int] NULL,
	[iverifystate] [int] NULL,
	[ireturncount] [int] NULL,
	[UAPRuntime_RowNO] [int] NULL,
	[UAP_VoucherTransform_Rowkey] [nvarchar](50) NULL,
	[dDate] [datetime] NULL,
PRIMARY KEY CLUSTERED 
(
	[custwork_work_PK] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_work_period]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_work_period](
	[cvencode] [nvarchar](100) NULL,
	[iyear] [int] NULL,
	[imonth] [int] NULL,
	[citemcode] [nvarchar](100) NULL,
	[fcreatedqty] [decimal](38, 10) NULL,
	[fquantity] [decimal](38, 10) NULL,
	[preqty] [decimal](38, 10) NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[custwork_works]    Script Date: 2024-10-24 12:25:46 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[custwork_works](
	[citemcode] [nvarchar](100) NULL,
	[custwork_works_PK] [int] NOT NULL,
	[custwork_work_PK] [int] NULL,
	[UAPRuntime_RowNO] [int] NULL,
	[UAP_VoucherTransform_Rowkey] [nvarchar](50) NULL,
	[RefMainID] [nvarchar](50) NULL,
	[RefRowID] [nvarchar](50) NULL,
	[fQuantity] [decimal](28, 10) NULL,
	[fcreatedqty] [decimal](28, 10) NULL,
PRIMARY KEY CLUSTERED 
(
	[custwork_works_PK] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY]
) ON [PRIMARY]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_ccqty]  DEFAULT ((0)) FOR [ccqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_djqty]  DEFAULT ((0)) FOR [djqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_preqty]  DEFAULT ((0)) FOR [preqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_balqty]  DEFAULT ((0)) FOR [balqty]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb]  DEFAULT ((0)) FOR [curcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb1]  DEFAULT ((0)) FOR [curcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb2]  DEFAULT ((0)) FOR [curcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb3]  DEFAULT ((0)) FOR [curcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb4]  DEFAULT ((0)) FOR [curcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb5]  DEFAULT ((0)) FOR [curcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb6]  DEFAULT ((0)) FOR [curcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb7]  DEFAULT ((0)) FOR [curcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb8]  DEFAULT ((0)) FOR [curcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb9]  DEFAULT ((0)) FOR [curcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb10]  DEFAULT ((0)) FOR [curcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb11]  DEFAULT ((0)) FOR [curcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb12]  DEFAULT ((0)) FOR [curcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb13]  DEFAULT ((0)) FOR [curcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb14]  DEFAULT ((0)) FOR [curcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb15]  DEFAULT ((0)) FOR [curcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb16]  DEFAULT ((0)) FOR [curcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb17]  DEFAULT ((0)) FOR [curcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb18]  DEFAULT ((0)) FOR [curcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_curcb19]  DEFAULT ((0)) FOR [curcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb]  DEFAULT ((0)) FOR [jzcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb1]  DEFAULT ((0)) FOR [jzcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb2]  DEFAULT ((0)) FOR [jzcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb3]  DEFAULT ((0)) FOR [jzcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb4]  DEFAULT ((0)) FOR [jzcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb5]  DEFAULT ((0)) FOR [jzcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb6]  DEFAULT ((0)) FOR [jzcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb7]  DEFAULT ((0)) FOR [jzcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb8]  DEFAULT ((0)) FOR [jzcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb9]  DEFAULT ((0)) FOR [jzcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb10]  DEFAULT ((0)) FOR [jzcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb11]  DEFAULT ((0)) FOR [jzcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb12]  DEFAULT ((0)) FOR [jzcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb13]  DEFAULT ((0)) FOR [jzcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb14]  DEFAULT ((0)) FOR [jzcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb15]  DEFAULT ((0)) FOR [jzcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb16]  DEFAULT ((0)) FOR [jzcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb17]  DEFAULT ((0)) FOR [jzcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb18]  DEFAULT ((0)) FOR [jzcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzcb19]  DEFAULT ((0)) FOR [jzcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb]  DEFAULT ((0)) FOR [jzqcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb1]  DEFAULT ((0)) FOR [jzqcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb2]  DEFAULT ((0)) FOR [jzqcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb3]  DEFAULT ((0)) FOR [jzqcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb4]  DEFAULT ((0)) FOR [jzqcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb5]  DEFAULT ((0)) FOR [jzqcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb6]  DEFAULT ((0)) FOR [jzqcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb7]  DEFAULT ((0)) FOR [jzqcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb8]  DEFAULT ((0)) FOR [jzqcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb9]  DEFAULT ((0)) FOR [jzqcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb10]  DEFAULT ((0)) FOR [jzqcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb11]  DEFAULT ((0)) FOR [jzqcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb12]  DEFAULT ((0)) FOR [jzqcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb13]  DEFAULT ((0)) FOR [jzqcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb14]  DEFAULT ((0)) FOR [jzqcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb15]  DEFAULT ((0)) FOR [jzqcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb16]  DEFAULT ((0)) FOR [jzqcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb17]  DEFAULT ((0)) FOR [jzqcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb18]  DEFAULT ((0)) FOR [jzqcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_jzqcb19]  DEFAULT ((0)) FOR [jzqcb19]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb]  DEFAULT ((0)) FOR [avgcb]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb1]  DEFAULT ((0)) FOR [avgcb1]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb2]  DEFAULT ((0)) FOR [avgcb2]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb3]  DEFAULT ((0)) FOR [avgcb3]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb4]  DEFAULT ((0)) FOR [avgcb4]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb5]  DEFAULT ((0)) FOR [avgcb5]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb6]  DEFAULT ((0)) FOR [avgcb6]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb7]  DEFAULT ((0)) FOR [avgcb7]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb8]  DEFAULT ((0)) FOR [avgcb8]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb9]  DEFAULT ((0)) FOR [avgcb9]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb10]  DEFAULT ((0)) FOR [avgcb10]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb11]  DEFAULT ((0)) FOR [avgcb11]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb12]  DEFAULT ((0)) FOR [avgcb12]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb13]  DEFAULT ((0)) FOR [avgcb13]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb14]  DEFAULT ((0)) FOR [avgcb14]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb15]  DEFAULT ((0)) FOR [avgcb15]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb16]  DEFAULT ((0)) FOR [avgcb16]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb17]  DEFAULT ((0)) FOR [avgcb17]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb18]  DEFAULT ((0)) FOR [avgcb18]
GO

ALTER TABLE [dbo].[custwork_detailinfo] ADD  CONSTRAINT [DF_custwork_detailinfo_avgcb19]  DEFAULT ((0)) FOR [avgcb19]
GO


